Closed
[dead-code] chore: remove obsolete modelsdev catalog pricing API#48739
Conversation
5 tasks
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Remove dead functions from catalog model
[dead-code] chore: remove obsolete modelsdev catalog pricing API
Jul 28, 2026
pelikhan
marked this pull request as ready for review
July 28, 2026 21:51
Contributor
There was a problem hiding this comment.
Pull request overview
Removes the obsolete models.dev pricing API while retaining normalization helpers used by CLI cost logic.
Changes:
- Removed pricing catalog implementation and tests.
- Retained normalization APIs and coverage.
- Updated package documentation for the reduced API.
Show a summary per file
| File | Description |
|---|---|
pkg/modelsdev/catalog.go |
Removes catalog pricing logic. |
pkg/modelsdev/catalog_test.go |
Deletes obsolete pricing tests. |
pkg/modelsdev/spec_test.go |
Removes pricing API specifications. |
pkg/modelsdev/README.md |
Documents normalization-only behavior. |
Review details
Tip
Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- Files reviewed: 4/4 changed files
- Comments generated: 1
- Review effort level: Medium
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This change removes dead
pkg/modelsdevpricing-catalog code and the tests/specs that only exercised that API surface. It keeps the normalization helpers still used by CLI cost logic and updates package-local docs to match the reduced public surface.API surface reduction (
pkg/modelsdev)catalog.go:FindPricingensureCatalogdownloadAndParseCatalogparseCatalogparseCostMapNormalizeProviderandNormalizeComparableModelIDremain as the package’s active public API.Test/spec cleanup
pkg/modelsdev/catalog_test.go(tests tied to removed catalog/pricing internals).TestSpec_PublicAPI_FindPricingandTestSpec_DesignDecision_ProviderAliasesfrompkg/modelsdev/spec_test.go.Documentation alignment
pkg/modelsdev/README.mdto remove pricing lookup references/examples and describe the normalization-only API.